package com.liugui.provider.service;

import com.alibaba.dubbo.config.annotation.Service;
import com.liugui.api.pojo.User;
import com.liugui.api.service.UserService;
import org.springframework.stereotype.Component;

import java.rmi.RemoteException;

/**
 * @ClassName: UserServiceImpl
 * @Author: liugui
 * @Date: 2021-03-21 11:29
 **/
@Service(interfaceClass = UserService.class)
@Component
public class UserServiceImpl implements UserService {
    @Override
    public User selectUserById(Integer userId) throws RemoteException {
        User user = new User(userId,"liugui");
        System.out.println("服务提供方，接收到请求的ID：" + userId);
        return user;
    }
}
